<?
$pageName = "courseClasses";
include ROOT . '/view/common/teacher/header.php';
?>
	<div class="container">
        <div class="page-header">
            <br /><br />
            <h2>
                <label>授课班</label>
            </h2>
        </div>
        <div class="row" style="margin-bottom:30px;">
            <div class="col-xs-12">
                <h3>
	                授课班 <small>共计<?=count($courseClasses)?>个</small>
				</h3>
				<table class="table table-striped">
					<thead>
					<tr>
						<th>课程名</th>
						<th>上课时间</th>
						<th>学期</th>
						<th>人数</th>
						<th>教室</th>
						<th>成绩管理</th>
					</tr>
					</thead>
					<tbody>
						<? foreach($courseClasses as $courseClass) {?>
						<tr>
							<td><?=Course::load($courseClass->courseId)->name?></td>
							<td>
								<?
									foreach ($classTimes[$courseClass->id] as $classTime) echo "{$classTime->showDay()}&nbsp;&nbsp;&nbsp;{$classTime->startTime}-{$classTime->endTime}节<br/>";
								?>
							</td>
							<td><?=$courseClass->semester?></td>
							<td><?=$courseClass->capacity?></td>
							<td><?=Classroom::load($courseClass->classroomId)->name?></td>
							<td><a href="/teacher/scoreList/?courseClassId=<?=$courseClass->id?>">查看详情</a>
						</tr>
						<?}?>
					</tbody>
				</table>
			</div>
		</div>
	</div>
<!-- .row -->
<center><div class="subpages row"><ul class="pagination pagination-sm"></ul></div></center>
</div>